Multiple positioning modules that are configured to locate the mobile terminal may be integrated in a mobile terminal. The positioning modules are, for example, a Global Navigation Satellite System (English: Global Navigation Satellite System, GNSS for short) module, a wireless local area network (English: Wireless Local Area Network, WLAN for short) module, a Bluetooth module, or an inertial sensor. When the mobile terminal is located outdoors, a positioning working mode of the mobile terminal is set to an outdoor positioning working mode, and in this mode, a GNSS is used to locate the mobile terminal. When the mobile terminal is located indoors, the positioning working mode of the mobile terminal is set to an indoor positioning working mode, and in this mode, at least one of a WLAN module, a Bluetooth module, or an inertial sensor is used to locate the mobile terminal. An important technology in the positioning field is that a positioning working mode needs to be switched when a mobile terminal moves into a building from outside.
In the prior art, a mobile terminal in which a GNSS is integrated can receive satellite signals transmitted by multiple satellites. In an indoor environment, for reasons such as that the mobile terminal is blocked by a building, strength of the satellite signals received by the mobile terminal may be reduced. In this case, the mobile terminal obtains an average value of strength of all the received satellite signals. If the average value is less than a preset threshold, it may be considered that the mobile terminal is located indoors, and a positioning mode is set to an indoor positioning mode.
However, in an urban street with dense skyscrapers on both sides, satellite signals that are transmitted by satellites and that are received by a mobile terminal usually arrive after reflection, diffraction, and the like during propagation, and have relatively weak strength. As a result, the mobile terminal may incorrectly determine, according to an average value of strength, that the mobile terminal is located indoors while the mobile terminal is located outdoors, which reduces positioning accuracy.